﻿using IMark.DAO;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace IMark.UC
{
	public partial class LogoAndSearchCtrl : System.Web.UI.UserControl
	{
		protected void Page_Load(object sender, EventArgs e)
		{
            if(!IsPostBack)
            {
                List<LOAI_SAN_PHAM> ltLoaiSP = LoaiSanPhamModels.GetAll().Where(w=>w.MaLoaiCha==0).ToList();
                StringBuilder str = new StringBuilder();
                foreach (var item in ltLoaiSP)
                {
                    str.Append("<li><a href='#a' data-value='"+item.ID+"'>"+item.TenLoai+"</a></li>");
                }
                dlCategori.InnerHtml = str.ToString();
            }
		}
	}
}